<template>
  {{ current }}
  <div></div>
  <button @click="add(1)">+1</button>
  <button @click="dec(1)">-1</button>
  <button @click="reset">重置</button>
  <hr />
  <testChild :value="testObj"></testChild>
</template>
<script setup lang="ts">
import testChild from "./testChild.vue";
import { useCount } from "./useCount";
const { current, add, dec, set, reset, testObj } = useCount(0);
setTimeout(() => {
  testObj.name = "xxxxxxx";
  testObj.data.data.data = { name: "yyyyy" };
  console.log(testObj)
}, 5000);
</script>
